package controllers

import (
	"LogServer/models"
)

//将数据封装成标准格式
//结构体中的属性应该大写开头，否则json获取不到它的属性值
type BaseReq struct{

}
type BaseResp struct{
	State	int `json:"state"`
	Msg		string `json:"msg"`
}
type UploadReq struct{
	BaseReq
	Action   string `json:"action"`
	Uid      int	`json:"uid"`
	Classid  int	`json:"classid"`
	Teaid    int	`json:"teaid"`
	Stuid    int	`json:"stuid"`
	Ts       string	`json:"ts"`
	Note     string `json:"note"`
	Roomid   string `json:"roomid"`
	Traceid  string `json:"traceid"`
	Bookid   string `json:"bookid"`
	Schoolid int	`json:"schoolid"`
}
type UploadResp struct {
	BaseResp

}
type PraiseReq struct{
	BaseReq
	teacherid	int `json:"teacherid"`
	classid		int	`json:"classid"`
}

type XXXReq struct{
	BaseReq
}

type XXXResp struct{
	BaseReq
}

//type PraiseResp struct {
//	State   int    `json:"state"`
//	Msg     string `json:"msg"`
//	Content struct {
//		Students []*Student        `json:"students"`
//	}`json:"content"`
//}
type PraiseResp struct {
	State  int    `json:"state"`
	Msg    string `json:"msg"`
	Result struct {
		Students []*models.Student `json:"students"`
	}	`json:"result"`
}


type TeachingInfoResp struct {
	State  int    `json:"state"`
	Msg    string `json:"msg"`
	Result struct {
	Teached	models.TeachedResult `json:"teached"`
	}	`json:"result"`
}

type TeacherTimeResp struct{
	BaseResp
	Result struct{
		TeacherTime []*models.TeacherTime	`json:"teacherlist"`
	}	`json:"result"`
}
type	TeachingRateResp struct{
	BaseResp
	Result struct{
		TeachingRate []*models.TeachingRate	 `json:"teacherlist"`
	}	`json:"result"`
}

type TeacherDataResp struct {
	BaseResp
	Result struct{
		TeacherDatas  []*models.TeacherData	`json:"teacherlist"`
	}	`json:"result"`
}


